home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Monster Media 1994 #2
/
Monster Media No. 2 (Monster Media)(1994).ISO
/
math
/
eval30.zip
/
DEMO.BAT
next >
Wrap
DOS Batch File
|
1994-06-30
|
799b
|
39 lines
rem
rem This batch file demonstrates EVAL.EXE
rem
rem Calculate the sum of 2,3,5,7 and 11.
EVAL 2+3+5+7+11
pause
rem Find 2 to the power of (3+7).
EVAL 2^(3+7)
pause
rem Find the sum of 12 eight-sided dice rolled randomly
rem and add 2 to the result.
rem (For RPG players, this is 12d8+2)
EVAL 12?8+2
pause
rem Find the TAN of 30 degrees.
EVAL TAN(30*PI/180)
pause
rem Convert the number 123,456 to hex.
EVAL 123456,x
pause
rem Convert the number 500 to binary.
EVAL 500,b
pause
rem Convert the number 10000 to base 4.
EVAL 10000,4
pause
rem Convert the hex number 01AB to decimal.
EVAL 0x1AB
pause
rem Convert the hex number 12 to binary
EVAL 0x12,b
pause
rem Add the hex number 100 to the decimal number 100
EVAL 0x100+100
pause
rem Show PI in hex
EVAL PI,x